package com.filefilter.start;


import com.filefilter.asyn.AsynTask;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.CommandLineRunner;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

/**
 * \* Created with IntelliJ IDEA.
 * \* Author: fly
 * \* Date: 2020/6/14
 * \* Time: 21:07
 * \* Description:
 * \
 */
@Component
public class FileMonitor implements CommandLineRunner {

    @Resource
    private AsynTask task;

    /**
     * description ： Springboot启动后， 执行
     * @param args
     * @throws Exception
     */
    @Override
    public void run(String... args) throws Exception {
        task.taskOne();
    }
}

